<?php

class Anwsermodel extends Model {

    public function __construct() {
        parent::Model();
    }

    public function find($id) {
        $this->db->where(array('id' => $id));
        $this->db->limit(1);
        $query = $this->db->get('anwser');
        return $query->num_rows() > 0?$query->row():false;
    }

    public function a_count() {
        return $this->db->count_all('anwser');
    }

    public function a_list($limit, $offset) {
        $this->db->limit($limit, $offset);
        return $this->db->get('anwser')->result();
    }

}